{% extends "admin/base_site.html" %}
{% load i18n %}

{% block breadcrumbs %}
    <div class="breadcrumbs">
      <a href="../../{{ link }}">
        {% trans "Home" %}
      </a>
       &rsaquo;
       <a href="../{{ link }}">
         {{ title }}
      </a>
      &rsaquo;
      {% if link %}
        <a href="{{ link }}">
          Admin log
        </a>
        &rsaquo;
        {% firstof user.get_full_name user contenttype %}
      {% else %}Admin log{% endif %}
    </div>
{% endblock %}

{% block content %}
<div id="content-main">
  <div class="module">
    <table summary="Actions">
      <tbody>
        <tr>
          <th>Action Time</th>
          <th>User</th>
          <th>ContentType</th>
          <th>View</th>
          <th>Object</th>
          <th>Action</th>
          <th>Message</th>
        </tr>
          {% for action in actions.object_list %}
            <tr>
                <td>{{ action.action_time }}</td>
                <td><a href="{% url hyperlog_show_admin_user_log action.user.pk %}">
                        {% firstof action.user.get_full_name action.user %}</a>
                </td>
                <td>
                    <a href="{% url hyperlog_show_admin_object_log action.content_type.pk action.object_id %}">
                        {{ action.content_type }}</a>
                </td>
                <td>
                    &nbsp;<a href="../../{{ link }}{{ action.get_admin_url }}" class="changelink">&nbsp;</a>
                </td>
                <td>{{ action.object_repr }}</a></td>
                <td>{{ action.hyperlog_action_flag }}</td>
                <td>{{ action.change_message }}</td>
            </tr>
          {% endfor %}
      </tbody>
    </table>
    <div class="pagination"><span class="step-links">
        {% if actions.has_previous %}
            <a href="?page={{ actions.previous_page_number }}">previous</a>
        {% endif %}
        <span class="current">
            Page {{ actions.number }} of {{ actions.paginator.num_pages }}.
        </span>
        {% if actions.has_next %}
            <a href="?page={{ actions.next_page_number }}">next</a>
        {% endif %}
    </span></div>
  </div>
</div>
{% endblock %}
        
{% block sidebar %}
{% endblock %}
